package com.zyk.scaffold.user.service;

import com.zyk.scaffold.core.domain.PageFilter;
import com.zyk.scaffold.core.domain.PageResult;
import com.zyk.scaffold.user.controller.tenantuser.*;
import com.zyk.scaffold.user.entity.Tenant;
import com.zyk.scaffold.user.entity.TenantUser;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

/**
 * <p>
 * 租户-用户-部门关系 服务类
 * </p>
 *
 * @author zhouyk
 * @since 2022-11-04
 */
public interface TenantUserService extends IService<TenantUser> {

    List<Tenant> getTenantInfos(Long userId);

    TenantUser getTenantUserInfo(String tenantCode, Long userId);

    Boolean addTenantUser(TenantUserNewRequ tenantUserNewRequ, Long userId, String tenantCode);

    PageResult<TenantUserInfosResp> pageFilterTenantUser(PageFilter<TenantUserPageFilterRequ> pageFilter, String tenantCode);

    Boolean editedTenantUser(TenantUserEditedRequ tenantUserEditedRequ, Long userId, String tenantCode);

    Boolean deletedTenantUser(TenantUserDeletedRequ tenantUserDeletedRequ, Long userId, String tenantCode);

    Boolean disabledTenantUser(TenantUserDisableRequ tenantUserDisableRequ, Long userId, String tenantCode);

    Boolean enabledTenantUser(TenantUserEnableRequ tenantUserEnableRequ, Long userId, String tenantCode);

    TenantUser loadTenantUserByUserId(Long userId, String tenantCode, Boolean enable);

    List<TenantInfoResp> tenantList(Long userId);
}
